package hcn.protocol.brandnew.feiyong.shoufei;

import lombok.Data;
import org.atag.sysrouter.annotation.DictionaryMapping;

import javax.xml.bind.annotation.*;
import java.util.List;


/**
 * 门诊结算信息新增-响应消息(成功) - ODS_04010002_SUC
 *
 * @author enjoyLife
 */
@Data
@XmlRootElement(name = "Data")
@XmlAccessorType(XmlAccessType.FIELD)
public class NotifyPayedResponse {

    /**
     * 就诊医疗机构组织机构代码
     */
    @XmlElement(name = "VisitOrganization")
    private String visitOrganization;
    /**
     * 就诊机构名称
     */
    @XmlElement(name = "VisitOrganizationName")
    private String visitOrganizationName;
    /**
     * 结算标识
     */
    @XmlElement(name = "PaymentNumber")
    private String paymentNumber;
    /**
     * 第三方交易流水号
     */
    @XmlElement(name = "AgtOrderNumber")
    private String agtOrderNumber;
    /**
     * 预结算标识
     */
    @XmlElement(name = "PaymentBudgetNumber")
    private String paymentBudgetNumber;
    /**
     * 发票号码
     */
    @XmlElement(name = "InvoiceCode")
    private String invoiceCode;
    /**
     * 收费单据集合
     */
    @XmlElementWrapper(name = "FeeRecordLists")
    @XmlElement(name = "FeeRecordList")
    private List<FeeRecordList> feeRecordLists;

    @Data
    @XmlAccessorType(XmlAccessType.FIELD)
    public static class DetailsItemList {

        /**
         * 费用项目代码
         */
        @XmlElement(name = "CostId")
        private String costId;
        /**
         * 费用项目名称
         */
        @XmlElement(name = "CostName")
        private String costName;
        /**
         * 费用数量
         */
        @XmlElement(name = "CostNumber")
        private String costNumber;
        /**
         * 费用单价
         */
        @XmlElement(name = "CostPrice")
        private String costPrice;
        /**
         * 总计金额
         */
        @XmlElement(name = "TotalCost")
        private String totalCost;
    }

    @Data
    @XmlAccessorType(XmlAccessType.FIELD)
    public static class FeeRecordList {

        /**
         * 收费单据标识
         */
        @XmlElement(name = "FeeNo")
        private String feeNo;
        /**
         * 类型代码
         */
        @XmlElement(name = "FeeTypeCode")
        @DictionaryMapping(id = "hcn.base.dictionary.HCN_feeType")
        private String feeTypeCode;
        /**
         * 类型名称
         */
        @XmlElement(name = "FeeTypeName")
        private String feeTypeName;
        /**
         * 申请单编号
         */
        @XmlElement(name = "RequestId")
        private String requestId;
        /**
         * 就诊流水号
         */
        @XmlElement(name = "VisitId")
        private String visitId;
        /**
         * 项目明细集合
         */
        @XmlElementWrapper(name = "DetailsItemLists")
        @XmlElement(name = "DetailsItemList")
        private List<DetailsItemList> detailsItemLists;
    }

}
